package com.yykj.tencent.im.server.utils;

import com.google.gson.Gson;
import com.google.gson.GsonBuilder;


public class GsonUtil {

	private final static Gson GSON = new GsonBuilder().create();

	public static String toJson(Object obj){
		return GSON.toJson(obj);
	}

	public static <T> T fromJson(String json,Class<T> clazz){
		return GSON.fromJson(json, clazz);
	}


}
